Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change default max-transaction-time #1655

Merged
merged 20 commits into from
Sep 22, 2023
Merged

Conversation

heifner
Copy link
Member

@heifner heifner commented Sep 19, 2023

  • Default max-transaction-time changed from 30ms to 499ms.
    • Node operators are encouraged to comment out max-transaction-time config setting and use the default. Setting max-transaction-time value to be greater than the on-chain consensus value max_transaction_cpu_usage means the on-chain value is the limiting factor. This allows the value to be set universally for all nodes by changing the on-chain consensus value of max_transaction_cpu_usage. Currently this is set to 150ms on EOS Mainnet. https://bloks.io/account/eosio?loadContract=true&tab=Tables&account=eosio&scope=eosio&limit=100&table=global
  • Force read-only transactions to run in the read-only thread pool specified by the read-only-threads option.
    • With the new large default for max-transaction-time, read-only transactions are effectively limited by read-only-read-window-time-us because it is less than max-transaction-time. Since, long-running read-only transactions are desired, they have been moved to run exclusively on read-only threads. A node that is not configured with read-only-threads greater than 0 will immediately fail any read-only transactions with error unsupported_feature: read-only transactions execution not enabled on API node. Set read-only-threads > 0.
  • Includes a fix for producer_plugin shutdown which properly stops the read-only thread-pool. This fix should be back-ported to 4.0.x.

Resolves #1639

@heifner heifner added the OCI Work exclusive to OCI team label Sep 19, 2023
greg7mdp

This comment was marked as outdated.

@heifner heifner requested a review from greg7mdp September 20, 2023 17:15
Copy link
Contributor

@greg7mdp greg7mdp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice change, try as I might I couldn't find anything wrong with it!

// as tasks will never execute. User is responsible for not queueing
// read_exclusive tasks if no read-only thread pool is available.
};

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can show an example of what read_only queue and read_exclusive queue store.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You mean add a comment that says that read_exclusive is currently only for read-only trx processing?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

plugins/producer_plugin/producer_plugin.cpp Show resolved Hide resolved
plugins/producer_plugin/producer_plugin.cpp Outdated Show resolved Hide resolved
plugins/producer_plugin/producer_plugin.cpp Show resolved Hide resolved
plugins/producer_plugin/producer_plugin.cpp Outdated Show resolved Hide resolved
@heifner heifner requested a review from linh2931 September 22, 2023 14:23
@heifner heifner merged commit f16f24b into main Sep 22, 2023
22 checks passed
@heifner heifner deleted the GH-1639-max-trx-time-default branch September 22, 2023 15:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCI Work exclusive to OCI team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Raise max-transaction-time
3 participants